/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * OrderCarUI.java
 *
 * Created on 15-12-2010, 20:18:48
 */
package UILayer.Screens;

import ControlLayer.ActorController;
import ControlLayer.OrderController;
import ControlLayer.ProductController;
import ModelLayer.Actor;
import ModelLayer.Car;
import ModelLayer.CarColor;
import ModelLayer.CarEngine;
import ModelLayer.OrderLine;
import ModelLayer.Product;
import ModelLayer.Role;
import ModelLayer.Supplier;
import UILayer.MainGuiView;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.io.InvalidObjectException;
import java.util.ArrayList;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JOptionPane;

/**
 *
 * @author Evil
 */
public class OrderCarUI extends javax.swing.JPanel
{
    javax.swing.table.DefaultTableModel model;
    javax.swing.table.DefaultTableModel cartModel;
    ProductController pc = new ProductController();
    ArrayList<CarColor> colors = pc.getCarColor();
    ArrayList<CarEngine> engines = pc.getCarEngine();
    ArrayList<Car> cars = new ArrayList<Car>();
    ArrayList<Actor> actors = new ArrayList<Actor>();
    OrderController oc = new OrderController();
    ActorController ac = new ActorController();

    MainGuiView mainView;

    /** Creates new form OrderCarUI */
    public OrderCarUI(MainGuiView mainView)
    {
        initComponents();

        this.mainView = mainView;

        actors = ac.getActorsByRole(Role.Supplier);

        //Load CarMakeComboBox with the selected car brands.
        CarMakeComboBox.removeAllItems();

        CarMakeComboBox.addItem("Vælg leverandør");

        for (Actor actor : actors)
        {
            CarMakeComboBox.addItem(actor.getName());
        }

        //Listener, that listens for changes in the CarComboBox,
        //and changes the CarTable accordingly.
        ItemListener itemListener = new ItemListener()
        {
            public void itemStateChanged(ItemEvent itemEvent)
            {
                int state = itemEvent.getStateChange();

                if (state == ItemEvent.SELECTED)
                {
                    ProductController pc = new ProductController();

                    cars = pc.getProducts(itemEvent.getItem().toString());
                    populateCarTable();

                    int selectedCarBrandIndex = CarMakeComboBox.getSelectedIndex();
                    if (selectedCarBrandIndex > 0)
                    {
                        try
                        {
                            Supplier selectedSupplier = (Supplier) actors.get(selectedCarBrandIndex - 1).getRole(Role.Supplier);
                            int selectedSupplierID = selectedSupplier.getSupplierID();
                            oc.createCartOrder(selectedSupplierID);
                            databindCarColors();
                            databindCarEngine();
                            prepareCartTable();
                        }
                        catch (InvalidObjectException ex)
                        {
                            Logger.getLogger(OrderCarUI.class.getName()).log(Level.SEVERE, null, ex);
                        }
                    }
                }
            }
        };

        CarMakeComboBox.addItemListener(itemListener);

        prepareCartTable();
    }

    private void databindCarEngine()
    {
        //Populate the CarEngineComboBox with engine items.
        CarEngineComboBox.setEnabled(true);
        CarEngineComboBox.removeAllItems();
        for (CarEngine engine : engines)
        {
            CarEngineComboBox.addItem(engine.getEngineSize() + " - " + engine.getPrice());
        }
    }

    private void databindCarColors()
    {
        //Populate the CarColorComboBox with color items.
        CarColorComboBox.setEnabled(true);
        CarColorComboBox.removeAllItems();
        for (CarColor color : colors)
        {
            CarColorComboBox.addItem(color.getColor() + " - " + color.getPrice());
        }
    }

    //Prepare the CartTable for product items.
    public void prepareCartTable()
    {

        cartModel = new javax.swing.table.DefaultTableModel();
        CartTable.setModel(cartModel);

        cartModel.addColumn("Model");
        cartModel.addColumn("Antal døre");
        cartModel.addColumn("Motor");
        cartModel.addColumn("Farve");
        cartModel.addColumn("Pris");

    }

    //Prepare the CarTable for car items.
    public void prepareCarTable()
    {
        model = new javax.swing.table.DefaultTableModel();
        CarTable.setModel(model);

        model.addColumn("Model");
        model.addColumn("Antal døre");
        model.addColumn("Pris");

    }

    //Populate the CarTable with car items.
    public void populateCarTable()
    {
        prepareCarTable();
        for (Car car : cars)
        {
            model.addRow(new Object[]
                    {
                        car.getModel(),
                        car.getDoors(),
                        car.getCarPrice()
                    });
        }
    }

    private void bindDataToCart()
    {
        ArrayList<OrderLine> ol = oc.getCartOrder().getOrderLines();
        prepareCartTable();
        double FullPrice = 0;
        for (OrderLine orderLine : ol)
        {
            Product product = orderLine.getProduct();

            if (product instanceof Car)
            {
                Car carProduct = (Car) product;

                cartModel.addRow(new Object[]
                        {
                            carProduct.getModel(),
                            carProduct.getDoors(),
                            carProduct.getEngine(),
                            carProduct.getColor(),
                            carProduct.getPurchasePrice()
                        });

                FullPrice += carProduct.getPurchasePrice();


            }
        }

        jLabel5.setText(String.valueOf(FullPrice) + ",-");
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jPanel1 = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        CarTable = new javax.swing.JTable();
        CarMakeComboBox = new javax.swing.JComboBox();
        CarColorComboBox = new javax.swing.JComboBox();
        CarEngineComboBox = new javax.swing.JComboBox();
        jLabel4 = new javax.swing.JLabel();
        jLabel2 = new javax.swing.JLabel();
        jLabel1 = new javax.swing.JLabel();
        btnChooseProduct = new javax.swing.JButton();
        jLabel6 = new javax.swing.JLabel();
        jScrollPane3 = new javax.swing.JScrollPane();
        jTextAreaDescription = new javax.swing.JTextArea();
        jLabel7 = new javax.swing.JLabel();
        jTextQuantity = new javax.swing.JTextField();
        btnRemoveProduct = new javax.swing.JButton();
        jPanel2 = new javax.swing.JPanel();
        jScrollPane2 = new javax.swing.JScrollPane();
        CartTable = new javax.swing.JTable();
        jLabel3 = new javax.swing.JLabel();
        jLabel5 = new javax.swing.JLabel();
        btnCompleteOrder = new javax.swing.JButton();

        jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder("Find bil"));
        jPanel1.setName("jPanel1"); // NOI18N

        jScrollPane1.setName("jScrollPane1"); // NOI18N

        CarTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {null, null, null},
                {null, null, null},
                {null, null, null},
                {null, null, null}
            },
            new String [] {
                "Model", "Antal døre", "Pris"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        CarTable.setName("CarTable"); // NOI18N
        jScrollPane1.setViewportView(CarTable);
        CarTable.getColumnModel().getColumn(0).setResizable(false);
        CarTable.getColumnModel().getColumn(1).setResizable(false);
        CarTable.getColumnModel().getColumn(2).setResizable(false);

        CarMakeComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Mærke" }));
        CarMakeComboBox.setName("CarMakeComboBox"); // NOI18N
        CarMakeComboBox.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                CarMakeComboBoxActionPerformed(evt);
            }
        });

        CarColorComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "..." }));
        CarColorComboBox.setEnabled(false);
        CarColorComboBox.setName("CarColorComboBox"); // NOI18N

        CarEngineComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "..." }));
        CarEngineComboBox.setEnabled(false);
        CarEngineComboBox.setName("CarEngineComboBox"); // NOI18N
        CarEngineComboBox.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                CarEngineComboBoxActionPerformed(evt);
            }
        });

        jLabel4.setText("Farve");
        jLabel4.setName("jLabel4"); // NOI18N

        jLabel2.setText("Motor");
        jLabel2.setName("jLabel2"); // NOI18N

        jLabel1.setText("Vælg mærke af bil:");
        jLabel1.setName("jLabel1"); // NOI18N

        btnChooseProduct.setText("Tilføj til indkøbskurv");
        btnChooseProduct.setName("btnChooseProduct"); // NOI18N
        btnChooseProduct.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnChooseProductActionPerformed(evt);
            }
        });

        jLabel6.setText("Beskrivelse til produktet:");
        jLabel6.setName("jLabel6"); // NOI18N

        jScrollPane3.setName("jScrollPane3"); // NOI18N

        jTextAreaDescription.setColumns(20);
        jTextAreaDescription.setRows(5);
        jTextAreaDescription.setName("jTextAreaDescription"); // NOI18N
        jScrollPane3.setViewportView(jTextAreaDescription);

        jLabel7.setText("Antal");
        jLabel7.setName("jLabel7"); // NOI18N

        jTextQuantity.setText("1");
        jTextQuantity.setName("jTextQuantity"); // NOI18N

        btnRemoveProduct.setText("Fjern fra indkøbskurv");
        btnRemoveProduct.setName("btnRemoveItem"); // NOI18N
        btnRemoveProduct.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnRemoveProductActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(jLabel1)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(CarMakeComboBox, 0, 274, Short.MAX_VALUE))
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 374, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(btnRemoveProduct, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(btnChooseProduct, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jTextQuantity, javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(jScrollPane3, javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(CarColorComboBox, javax.swing.GroupLayout.Alignment.TRAILING, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jLabel2)
                    .addComponent(CarEngineComboBox, javax.swing.GroupLayout.Alignment.TRAILING, 0, 193, Short.MAX_VALUE)
                    .addComponent(jLabel4)
                    .addComponent(jLabel6)
                    .addComponent(jLabel7))
                .addContainerGap())
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel1)
                    .addComponent(CarMakeComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(jLabel2)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(CarEngineComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel4)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(CarColorComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jLabel6)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(13, 13, 13)
                        .addComponent(jLabel7)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextQuantity, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(btnChooseProduct)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnRemoveProduct))
                    .addComponent(jScrollPane1, 0, 0, Short.MAX_VALUE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        btnRemoveProduct.getAccessibleContext().setAccessibleName("btnRemoveItem");

        jPanel2.setBorder(javax.swing.BorderFactory.createTitledBorder("Indkøbskurv"));
        jPanel2.setName("jPanel2"); // NOI18N

        jScrollPane2.setName("jScrollPane2"); // NOI18N

        CartTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null}
            },
            new String [] {
                "Title 1", "Title 2", "Title 3", "Title 4"
            }
        ));
        CartTable.setName("CartTable"); // NOI18N
        jScrollPane2.setViewportView(CartTable);

        jLabel3.setText("Samlet pris:");
        jLabel3.setName("jLabel3"); // NOI18N

        jLabel5.setText("0,-");
        jLabel5.setName("jLabel5"); // NOI18N

        btnCompleteOrder.setText("Færdiggør ordre");
        btnCompleteOrder.setName("btnCompleteOrder"); // NOI18N
        btnCompleteOrder.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnCompleteOrderActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(jScrollPane2, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 508, Short.MAX_VALUE)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 70, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel5, javax.swing.GroupLayout.PREFERRED_SIZE, 92, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 229, Short.MAX_VALUE)
                        .addComponent(btnCompleteOrder)))
                .addContainerGap())
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 326, Short.MAX_VALUE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel3)
                    .addComponent(jLabel5)
                    .addComponent(btnCompleteOrder))
                .addContainerGap())
        );

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addComponent(jPanel2, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanel1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
    }// </editor-fold>//GEN-END:initComponents

    private void CarEngineComboBoxActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_CarEngineComboBoxActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_CarEngineComboBoxActionPerformed

    private void CarMakeComboBoxActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_CarMakeComboBoxActionPerformed
    }//GEN-LAST:event_CarMakeComboBoxActionPerformed

    private void btnChooseProductActionPerformed(java.awt.event.ActionEvent evt)//GEN-FIRST:event_btnChooseProductActionPerformed
    {//GEN-HEADEREND:event_btnChooseProductActionPerformed
        int selectedRow = CarTable.getSelectedRow();
        if (selectedRow > -1)
        {
            int quantity = Integer.parseInt(jTextQuantity.getText());

            Car car = cars.get(selectedRow);
            CarEngine engine = engines.get(CarEngineComboBox.getSelectedIndex());
            CarColor color = colors.get(CarColorComboBox.getSelectedIndex());

            Car newCar = new Car();

            newCar.setCarID(car.getCarID());
            newCar.setBrand(car.getBrand());
            newCar.setDescription(car.getDescription());
            newCar.setDoors(car.getDoors());
            newCar.setModel(car.getModel());
            newCar.setYear(car.getYear());

            newCar.setHk(engine.getHk());
            newCar.setEngine(engine.getEngineSize());
            newCar.setFuel(engine.getFuel());
            newCar.setColor(color.getColor());
            newCar.setPurchasePrice((car.getCarPrice() + engine.getPrice() + color.getPrice()) * 1);
            newCar.setQuantity(quantity);

            oc.getCartOrder().addProduct(newCar, quantity);
           
            bindDataToCart();
        }
    }//GEN-LAST:event_btnChooseProductActionPerformed

    private void btnCompleteOrderActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnCompleteOrderActionPerformed
        oc.completeOrder();
        JOptionPane.showMessageDialog(mainView.getFrame(), "Ordren blev gemt");
    }//GEN-LAST:event_btnCompleteOrderActionPerformed

    private void btnRemoveProductActionPerformed(java.awt.event.ActionEvent evt)//GEN-FIRST:event_btnRemoveProductActionPerformed
    {//GEN-HEADEREND:event_btnRemoveProductActionPerformed
        int selectedRow = CartTable.getSelectedRow();

        oc.getCartOrder().removeProduct(selectedRow);

        //CartTable.remove(selectedRow);
        bindDataToCart();

    }//GEN-LAST:event_btnRemoveProductActionPerformed

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JComboBox CarColorComboBox;
    private javax.swing.JComboBox CarEngineComboBox;
    private javax.swing.JComboBox CarMakeComboBox;
    private javax.swing.JTable CarTable;
    private javax.swing.JTable CartTable;
    private javax.swing.JButton btnChooseProduct;
    private javax.swing.JButton btnCompleteOrder;
    private javax.swing.JButton btnRemoveProduct;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JTextArea jTextAreaDescription;
    private javax.swing.JTextField jTextQuantity;
    // End of variables declaration//GEN-END:variables
}
